package com.mxpio.erp.common.equipment.entity;

import com.mxpioframework.filestorage.entity.MxpioFileInfo;
import com.mxpioframework.jpa.annotation.Generator;
import com.mxpioframework.jpa.policy.impl.UUIDPolicy;
import com.mxpioframework.security.annotation.Dict;
import com.mxpioframework.security.entity.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;


/**
 * 设备SOP对象 MB_ERP_EQUIPMENT_EQP_SOP
 *
 * @author Cheng
 * @date 2023-07-01
 */
@Data
@EqualsAndHashCode(callSuper=false)
@Entity
@Table(name = "MB_ERP_EQUIPMENT_EQP_SOP")
@Schema(description="设备SOP")
public class EquipmentEqpSop extends BaseEntity {

private static final long serialVersionUID=1L;

    @Id
    @Generator(policy = UUIDPolicy.class)
    @Column(name = "ID_")
    @Schema(description = "主键")
    private String id;

    @Column(name = "BASICS_CODE_")
    @Schema(description = "设备资产ID")
    @Dict(dicCode = "basicsCode", dicEntity = EquipmentEqpBasics.class, dicText = "eqpName")
    private String basicsCode;

    @Column(name = "SOP_TYPE_")
    @Schema(description = "SOP类型")
    @Dict(dicCode = "ERP_EQUIPMENT_GROUP_CATEGORY")
    private String sopType;

    @Column(name = "ATTR_URL_")
    @Schema(description = "附件")
    @Dict(dicCode = "fileNo", dicEntity = MxpioFileInfo.class, dicText = "fileName")
    private String attrUrl;

    @Column(name = "ATTR_NAME_")
    @Schema(description = "SOP名称")
    private String attrName;

    @Column(name = "IS_DEL_")
    @Schema(description = "是否删除（0-正常；1删除）")
    private Integer isDel;


}
